<template>
  <div>
    <app-topnav />
    <app-header />
    <!-- 吸顶头部 -->
    <AppHeaderSticky />
    <main class="app-body">
      <!-- 二级路由 -->
      <router-view></router-view>
    </main>
    <app-footer />
  </div>
</template>

<script>
import AppTopnav from '@/components/app-topnav'
import AppHeader from '@/components/app-header'
import AppFooter from '@/components/app-footer'
import AppHeaderSticky from '@/components/app-header-sticky'
import { useStore } from 'vuex'
export default {
  components: {
    AppTopnav,
    AppHeader,
    AppHeaderSticky,
    AppFooter
  },
  setup () {
    const store = useStore()

    store.dispatch('category/getList')
  }
}
</script>

<style lang="less" scoped>
.app-body {
  min-height: 600px;
}
</style>
